package com.example.domain;

import java.io.Serializable;
import java.sql.Timestamp;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.Table;

import com.fasterxml.jackson.annotation.JsonFormat;

/**
 * @author 袁小弘
 * @describe 培训中心学生管理————请假类
 * @date 2019-12-17 14:52
 */
@Entity
@Table(name = "ask_for_leave")
public class AskForLeave implements Serializable {

    private static final long serialVersionUID = 464478469634261444L;

    @Id
    @GeneratedValue
    @Column(name = "ask_Id")
    private Integer askId;//请假ID

    @Column(name = "user_Id", length = 32)
    private Integer userId;//学生ID

    @Column(name = "duration", length = 32)
    private String duration;//请假期限

    @Column(name = "reason", length = 255)
    private String reason;//请假原因

    @Column(name = "status", length = 10)
    private String status;//请假状态

    @Column(name = "startTime")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private Timestamp startTime;//请假开始时间

    @Column(name = "endTime")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private Timestamp endTime;//请假结束时间

    @Column(name = "comment", length = 255)
    private String comment;//备注说明

    @Column(name = "recordTime")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private Timestamp recordTime;//创建记录时间

    @Column(name = "updateTime")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private Timestamp updateTime;//更新记录时间


    public AskForLeave() {
        //无参构造
    }


    public Integer getAskId() {
        return askId;
    }


    public void setAskId(Integer askId) {
        this.askId = askId;
    }


    public Integer getUserId() {
        return userId;
    }


    public void setUserId(Integer userId) {
        this.userId = userId;
    }


    public String getDuration() {
        return duration;
    }


    public void setDuration(String duration) {
        this.duration = duration;
    }


    public String getReason() {
        return reason;
    }


    public void setReason(String reason) {
        this.reason = reason;
    }


    public String getStatus() {
        return status;
    }


    public void setStatus(String status) {
        this.status = status;
    }


    public Timestamp getStartTime() {
        return startTime;
    }


    public void setStartTime(Timestamp startTime) {
        this.startTime = startTime;
    }


    public Timestamp getEndTime() {
        return endTime;
    }


    public void setEndTime(Timestamp endTime) {
        this.endTime = endTime;
    }


    public String getComment() {
        return comment;
    }


    public void setComment(String comment) {
        this.comment = comment;
    }


    public Timestamp getRecordTime() {
        return recordTime;
    }


    public void setRecordTime(Timestamp recordTime) {
        this.recordTime = recordTime;
    }


    public Timestamp getUpdateTime() {
        return updateTime;
    }


    public void setUpdateTime(Timestamp updateTime) {
        this.updateTime = updateTime;
    }


    @Override
    public String toString() {
        return "AskForLeave [askId=" + askId + ", userId=" + userId + ", duration=" + duration + ", reason=" + reason
                + ", status=" + status + ", startTime=" + startTime + ", endTime=" + endTime + ", comment=" + comment
                + ", recordTime=" + recordTime + ", updateTime=" + updateTime + "]";
    }


}
